package net.wanho.mapper;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import net.wanho.po.Place;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

/**
* @author Administrator
* @description 针对表【place(产地表)】的数据库操作Mapper
* @createDate 2025-04-28 11:41:58
* @Entity net.wanho.po.Place
*/
public interface PlaceMapper extends BaseMapper<Place> {

    @Select("SELECT place_name FROM place WHERE place_id = #{placeId}")
    String selectPlaceName(Integer placeId);

    @Select("SELECT place_id FROM place WHERE place_name = #{placeName}")
    Integer selectIdByPlaceName(String placeName);

    Page<Place> selectByPage(Page<Place> page,@Param("ew") QueryWrapper<Place> wrapper);
}




